﻿<%@ Page Language="C#" MasterPageFile="~/admin_cms/admin_master.master" AutoEventWireup="true"
    CodeFile="Modul.aspx.cs" Inherits="admin_cms_Modul" Title="Untitled Page" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <div class="all_khung_form1">
        <div class="top_khung_form1">
            <h5>
                QUẢN LÝ MODULE</h5>
        </div>
        <div style="width: 48%; float: left; border-right: 1px solid #C2C3C4; padding-right: 18px;">
            <div style="float: left; width: 100%; background: #EDEDED; padding-right: 4px; height: 23px;
                -moz-box-shadow: 0 0 5px #888; -webkit-box-shadow: 0 0 5px#888; box-shadow: 0 0 5px #888;">
                <h3 style="font-size: 13px; margin-left: 43px; margin-top: 2px;">
                    Thêm module cha</h3>
            </div>
            <div class="khung_form1">
                <h3>
                    Tên Modul Cha:</h3>
                <asp:TextBox ID="txtcha" runat="server" class="txtform"></asp:TextBox>
            </div>
             <div class="khung_form1">
                <h3>
                    Vị trí hiển thị:</h3>
                <asp:TextBox ID="txtht" runat="server" class="txtform"></asp:TextBox>
            </div>
            <div class="khung_form1">
                <h3>
                    Ảnh đại diện:</h3>
                <asp:FileUpload ID="FileUpload1" runat="server" class="txtform" />
            </div>
            <div class="khung_form1" style="margin-top: 14px;">
                <asp:Button ID="Button2" runat="server" Text="Thêm module" Height="28px" OnClick="insertmodulcha" />
                <asp:Button ID="Button3" runat="server" Text="Sửa module" Height="28px" OnClick="updatemodulecha" />
            </div>
            <br />
            <div class="all_khung_form3">
                <div class="griv_content">
                    <asp:GridView ID="gricha" runat="server" CssClass="mGrid mgr_module gri_nua" PagerStyle-CssClass="pgr"
                        Font-Size="12px" AutoGenerateColumns="false" AlternatingRowStyle-BackColor="#DFE2E4"
                        OnRowCommand="grv_module_click">
                        <Columns>
                            <asp:BoundField HeaderText="Mã module" DataField="idmodule" />
                            <asp:BoundField HeaderText="Tên module" DataField="name_module" />
                            <asp:BoundField HeaderText="Vị trí hiển thị" DataField="sort" />
                            <asp:BoundField HeaderText="Linkweb" DataField="link_page" />
                        </Columns>
                        <Columns>
                            <asp:TemplateField HeaderText="Xóa">
                                <ItemTemplate>
                                    <asp:ImageButton runat="server" ImageUrl="~/admin_cms/style/images/icons/small/grey/Acces Denied Sign.png"
                                        CssClass="grivimg" ID="imgxoa" CommandArgument='<%#Eval("idmodule") %> ' CommandName="X" />
                                </ItemTemplate>
                            </asp:TemplateField>
                        </Columns>
                        <Columns>
                            <asp:TemplateField HeaderText="Sửa">
                                <ItemTemplate>
                                    <asp:ImageButton runat="server" ImageUrl="~/admin_cms/style/images/icons/small/grey/Create Write.png"
                                        ID="imgsua" CommandArgument='<%#Eval("idmodule") %> ' CommandName="S" />
                                </ItemTemplate>
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                </div>
            </div>
        </div>
        <div style="width: 48%; float: left; margin-left: 14px;">
            <div style="float: left; width: 100%; background: #EDEDED; padding-right: 11px; height: 23px;
                -moz-box-shadow: 0 0 5px #888; -webkit-box-shadow: 0 0 5px#888; box-shadow: 0 0 5px #888;">
                <h3 style="font-size: 13px; margin-left: 43px; margin-top: 2px;">
                    Thêm module con</h3>
            </div>
            <div class="khung_form1">
                <h3>
                    Chọn modul cha:</h3>
                <asp:DropDownList ID="drl_modul_cha" runat="server" Height="25px" Width="305px" class="txtform">
                </asp:DropDownList>
            </div>
            <div class="khung_form1">
                <h3>
                    Thêm modul con:</h3>
                <asp:TextBox ID="txtcon" runat="server" class="txtform"></asp:TextBox>
            </div>
            <div class="khung_form1">
                <h3>
                    Trang cần link:</h3>
                <asp:TextBox ID="txtlink" runat="server" class="txtform"></asp:TextBox>
            </div>
            <div class="khung_form1">
                <asp:Button ID="Button1" runat="server" Text="Thêm modul con" Height="28px" OnClick="insertmodulcon" />
                 <asp:Button ID="Button4" runat="server" Text="Sửa modul con" Height="28px" OnClick="updatetmodulcon" />
            </div>
            <div class="all_khung_form3">
                <div class="griv_content">
                    <asp:GridView ID="GriviewCon" runat="server" CssClass="mGrid mgr_module" PagerStyle-CssClass="pgr"
                        Font-Size="12px" AutoGenerateColumns="false" AlternatingRowStyle-BackColor="#DFE2E4"
                        OnRowCommand="grv_module_con_click">
                        <Columns>
                            <asp:BoundField HeaderText="Mã module" DataField="idmodule" />
                            <asp:BoundField HeaderText="Tên module" DataField="name_module" />
                            <asp:BoundField HeaderText="Linkweb" DataField="link_page" />
                        </Columns>
                        <Columns>
                            <asp:TemplateField HeaderText="Xóa">
                                <ItemTemplate>
                                    <asp:ImageButton runat="server" ImageUrl="~/admin_cms/style/images/icons/small/grey/Acces Denied Sign.png"
                                        CssClass="grivimg" ID="imgxoa" CommandArgument='<%#Eval("idmodule") %> ' CommandName="X" />
                                </ItemTemplate>
                            </asp:TemplateField>
                        </Columns>
                        <Columns>
                            <asp:TemplateField HeaderText="Sửa">
                                <ItemTemplate>
                                    <asp:ImageButton runat="server" ImageUrl="~/admin_cms/style/images/icons/small/grey/Create Write.png"
                                        ID="imgsua" CommandArgument='<%#Eval("idmodule") %> ' CommandName="S" />
                                </ItemTemplate>
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                </div>
            </div>
        </div>
    </div>
</asp:Content>
